
//
//  MessageCell.m
//  LuxuryGoods
//
//  Created by DCQ on 2018/5/25.
//  Copyright © 2018年 Future. All rights reserved.
//

#import "MessageCell.h"
#import "MessageListModel.h"
@interface MessageCell()
@property (weak, nonatomic) IBOutlet UIImageView *messageTypeImgV;
@property (weak, nonatomic) IBOutlet UILabel *messageTitle;
@property (weak, nonatomic) IBOutlet UILabel *messageDetail;

@end
@implementation MessageCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

- (void)setupMessageModel:(MessageModel *)model{
    if (model) {
        self.messageTitle.text = model.title;
        self.messageDetail.text = model.subtitle;
         NSString * imgName = @"";
        if ([model.type integerValue] == 3 || [model.type integerValue] == 4 ||[model.type integerValue] == 5 ||[model.type integerValue] == 6 ||[model.type integerValue] == 7 ) {
              imgName = @"xiaoxi_tongzhi";
        }else{
             imgName = @"xiaoxi_icon";
        }
       self.messageTypeImgV.image = [UIImage imageNamed:imgName];
    }
    
}
- (void)setupMessageReading:(BOOL)isReading{
    
    
}
@end
